package cn.dy.workatten.dao;

import cn.dy.base.framework.db.DBConnectPool;
import cn.dy.base.framework.db.util.DBExecuteUtil;
import cn.dy.workatten.pojo.ContactHolder;

import javax.sql.DataSource;

public class ContactHolderDao {
	private DataSource dataSource;
	private DBExecuteUtil db;

	public ContactHolderDao() {
		this.db = new DBExecuteUtil();
		this.dataSource = DBConnectPool.create().getDataSource();
	}

	public int createHolder(ContactHolder contactHolder) throws Exception {
		return this.db.insert(contactHolder, "ecc_contact_holder");
	}
}
